package com.ely.coupon.activity.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.math.BigDecimal;
import java.util.Date;

import lombok.Data;

/**
 * 活动优惠券
 */
@Data
@TableName(value = "coupon_activity")
public class CouponActivity {
    /**
     * 主键
     */
    @TableId(value = "coupon_activity_id", type = IdType.ASSIGN_ID)
    private Long couponActivityId;

    /**
     * 卡券名称
     */
    @TableField(value = "coupon_name")
    private String couponName;

    /**
     * 1 表示 无门槛 2 表示满减,3 表示折扣券,4 随机立减
     */
    @TableField(value = "coupon_type")
    private Integer couponType;

    /**
     * 满减
     */
    @TableField(value = "full_decrease_amount")
    private BigDecimal fullDecreaseAmount;

    /**
     * 满减金额
     */
    @TableField(value = "decrease_amount")
    private BigDecimal decreaseAmount;

    /**
     * 折扣
     */
    @TableField(value = "discount")
    private Integer discount;

    /**
     * 优惠卷限制规则 1 全平台 2 平台品类可用  3 商家可用,4 商家品类, 5 指定商品
     */
    @TableField(value = "coupon_scope")
    private Integer couponScope;

    /**
     * 最多领取数
     */
    @TableField(value = "max_receive_count")
    private Integer maxReceiveCount;

    /**
     * 优惠卷的库存
     */
    @TableField(value = "coupon_quantity")
    private Integer couponQuantity;

    /**
     * 1 临时 2 固定期限
     */
    @TableField(value = "expiry_date_type")
    private Integer expiryDateType;

    /**
     * 优惠券临时有效  表示领取天数
     */
    @TableField(value = "expiry_day")
    private Integer expiryDay;

    /**
     * 固定期限   开始时间
     */
    @TableField(value = "expiry_start_date")
    private Date expiryStartDate;

    /**
     * 固定期限   结束时间
     */
    @TableField(value = "expiry_end_date")
    private Date expiryEndDate;

    /**
     * 创建时间
     */
    @TableField(value = "create_date")
    private Date createDate;

    /**
     * 更新时间
     */
    @TableField(value = "update_date")
    private Date updateDate;

    /**
     * 0 表示未启用  1暂停  2下架
     */
    @TableField(value = "`status`")
    private Integer status;

    public static final String COL_COUPON_ACTIVITY_ID = "coupon_activity_id";

    public static final String COL_COUPON_NAME = "coupon_name";

    public static final String COL_COUPON_TYPE = "coupon_type";

    public static final String COL_FULL_DECREASE_AMOUNT = "full_decrease_amount";

    public static final String COL_DECREASE_AMOUNT = "decrease_amount";

    public static final String COL_DISCOUNT = "discount";

    public static final String COL_COUPON_SCOPE = "coupon_scope";

    public static final String COL_MAX_RECEIVE_COUNT = "max_receive_count";

    public static final String COL_COUPON_QUANTITY = "coupon_quantity";

    public static final String COL_EXPIRY_DATE_TYPE = "expiry_date_type";

    public static final String COL_EXPIRY_DAY = "expiry_day";

    public static final String COL_EXPIRY_START_DATE = "expiry_start_date";

    public static final String COL_EXPIRY_END_DATE = "expiry_end_date";

    public static final String COL_CREATE_DATE = "create_date";

    public static final String COL_UPDATE_DATE = "update_date";

    public static final String COL_STATUS = "status";
}